﻿<%@ Page Language="C#" MasterPageFile="~/Style/FrontEnd/FrontEnd.master" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="OnlineFloralShop.Product.Default" %>
    <asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">

    </asp:Content>
    <asp:Content ID="Content2" ContentPlaceHolderID="contentMain" runat="server">
    <p class="bigtitle_"><%= this.CategoryName %></p>
    <p style="background-color:#F8F8F8; padding:6px; margin-top:-1em;text-align:right;"><b>Sort By:</b> 
        <asp:DropDownList ID="DropDownList_OrderBy" runat="server" AutoPostBack="True" 
            onselectedindexchanged="DropDownList_OrderBy_SelectedIndexChanged">
        <asp:ListItem Selected="True" Value="ProductName ASC">Default</asp:ListItem>
        <asp:ListItem Value="ProductName ASC">Name A-Z</asp:ListItem>
        <asp:ListItem Value="ProductName DESC">Name Z-A</asp:ListItem>
        <asp:ListItem Value="Price ASC">Price Low-Hight</asp:ListItem>
        <asp:ListItem Value="Price DESC">Price Hight-Low</asp:ListItem>
        <asp:ListItem Value="DateAdded DESC">Date Last-First</asp:ListItem>
        <asp:ListItem Value="DateAdded ASC">Date First-Last</asp:ListItem>
        </asp:DropDownList>
     
     </p>
    
        <asp:ListView ID="ListView_Product" runat="server">
            <ItemTemplate>
            <div style='float:left; margin:5px; width:48%; background:#F3F3F3;'>
                <div style='margin:4px; padding:10px; border:1px solid #FFFFFF;'>
                <table width='100%' cellpadding='0' cellspacing='0'>
                  <tr>

                    <td valign='top'><div style='float:left; width:100px;'><a title='<%# Eval("ProductName") %>' href='Details.aspx?ProductId=<%# Eval("ProductId") %>' class='tips'>

                            <img id="Img1" width="100" height="100" title='<%# Eval("ProductName") %>' alt='<%# Eval("ProductName") %>' runat="server" src='<%# Eval("Images") %>' border="0" />
                        </a>
                    </div></td>
                    <td align='justify' valign='top' style='padding-left:10px; font-size:11px;'>
                        <div style='height:100px;'>
                            <b><a  title='<%# Eval("ProductName") %>'  href='Details.aspx?ProductId=<%# Eval("ProductId") %>' style='font-size:12px;'><%# Eval("ProductName") %></a></b> - <b><%# Eval("ProductId") %></b> <br />

                             <%# Eval("Description") %><br />
                            <b style='color:#BB0000; font-size:12px;'>Price: <%# decimal.Floor(decimal.Parse(Eval("Price").ToString()))%> $</b><br />
                            <b style='color:#BB0000; font-size:12px;'>Status: 
                                <asp:Label ID="Label_Status" runat="server" Text='<%# OnlineFloralShop.Common.CommonController.StatusStore(int.Parse(Eval("Quantity").ToString())) %>'></asp:Label> </b>
                        </div>
                        <div style='height:20px;'>
                            <a title='View details' class='viewdetail' href='Details.aspx?ProductId=<%# Eval("ProductId") %>' >Details</a>
                 
                            <a title='Order' class='viewdetail'  style='margin-left:5px;' href="../AddToCart.aspx?ProductId=<%# Eval("ProductId") %>" >Order</a>

                            <a title='View cart' class='viewdetail' style='margin-left:5px;' href="../Cart.aspx" >Basket</a>

                        </div>
                    </td>
                  </tr>
                </table>
               </div>
            </div>
            </ItemTemplate>
            <EmptyDataTemplate>
                 <div style="border:solid 1px #dedede; margin:20px; padding:10px" >
                            <p>No Product</p>
                 </div>
            </EmptyDataTemplate>
            <LayoutTemplate>
                <div ID="itemPlaceholder" runat="server" ></div>
            </LayoutTemplate>
        </asp:ListView>	
         <div class='divclear'></div>	
          <p style="border:1px solid #F3F3F3; font-weight: bold; font-size: 13px; padding: 3px 0px; text-align:right; ">
              <asp:Label ID="lbPrev" runat="server" Text=""></asp:Label><asp:Label ID="lbPaging"
                  runat="server" Text=""></asp:Label><asp:Label ID="lbNext" runat="server" Text=""></asp:Label></p>
   </asp:Content>
   